<template lang="jade">
h-loader-full(url='loader')
  h-data-updater(url='sginip/uprow')
  div
    m-title(icon='add',name='编辑公司')
    table.single(v-for='n in list')
      mf-row(name='序号')
        span {{n.id}}
      mf-row(name='公司名称')
        span {{n.cname}}
      mf-row(name='公司性质')
        span {{n.nature}}
      mf-row(name='公司地址')
        span {{n.address}}
      mf-row(name='公司邮箱')
        span {{n.email}}
      mf-row(name='联系人姓名')
        span {{n.contact_name}}
      mf-row(name='联系人电话')
        span {{n.contact_mobile}}
      mf-row(name='公司简介')
        textarea {{n.intro}}
      mf-row(name='营业执照')
        <img :src="'http://image.mod.hesq.com.cn/xiongan/license/'+n.license">
      mf-row(name='公司logo')
        <img :src="'http://image.mod.hesq.com.cn/xiongan/logo/'+n.logo">
      mf-row(name='公司状态')
        select(v-model='p.examine') 
          option(v-for='w in examine', :value='w.examine') {{w.name}}
      mf-row(name='')
        button(@click='mine') 确认提交
</template>
----------------------------------------------------------------------------------------
<script>
import { MessageBox } from 'mint-ui'
export default {
	data () {
		return {
			loader:{
        list:'get_company/datail/'+this.$query.get('id'),
        },
      list:[],
      examine:[{examine:1,name:'审核通过'},{examine:2,name:'审核未通过'}],
      p:{
        id:'',
        examine:'',
        name:''
      }
		}
	},
  mounted () {
  },
	methods: {
		loadAfter(data){
      this.list=data.list[0]
      this.p.id = this.list[0].id
      this.p.status = this.list[0].status
      this.p.name = this.list[0].cname
		},
    mine(){
      console.log(this.p)
      this.$ajax.put('company/examine', this.p ,(res)=>{
        this.$msg.success('修改成功')
        setTimeout("window.location.href='company_examine.html'",1000)
      },(res)=>{
        this.$msg.error('修改失败')
      })
    }
	}
}
</script>
----------------------------------------------------------------------------------------
<style lang="less" scoped>
@import "../../../plugin/style/mixin";
#mymap{ .bsol(#f0f0f0, 2); }
	.command{ .bn; 
		button{ .fr; .mr(2%); }
	}
	input.input{ .mr(10); .r(5); outline:none; }
	.a{ .td(none); }
  img{ .w(80); }
.top { .bk(#006dcc); .c(#fff); .p(5); .td(none); dispaly:inline-block; .ml(5);}
	.command{ .bn; 
		button{ .fr; .mr(2%); float:right; }
	}
	input.input{ .mr(10); .r(5); outline:none; }
	.a{ .td(none); }
  img{ .w(250); .h(250); }
  textarea{ .w(500); .h(60); }
</style>